package tech.aistar.day01;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * 本类功能:
 *
 * @author cxylk
 * @date 2020/9/21 12:22
 */
@WebServlet("/day01/index")
public class IndexDataAction extends HttpServlet {
    @Override
    protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        req.setAttribute("username","admin");
        req.getRequestDispatcher("/index.jsp").forward(req,resp);
    }
}
